import Vue from 'vue'
import Router from 'vue-router'
import register from '../components/register'
import login from '../components/login'
import home from '../components/home'
import home1 from '../components/home/home1'
import home2 from '../components/home/home2'
import home3 from '../components/home/home3'
import home21 from '../components/home/home2/home21'
import home22 from '../components/home/home2/home22'
import home23 from '../components/home/home2/home23'
import home31 from '../components/home/home3/home31'
import home32 from '../components/home/home3/home32'

Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      name: 'login',
      component: login
    },
    {
      path: '/home',
      name: 'home',
      component: home,
      children: [
        { path: 'home1', component: home1 },
        { path: 'home2',
          component: home2,
          children: [
            { path: 'home21', component: home21 },
            { path: 'home22', component: home22 },
            { path: 'home23', component: home23 }
          ]},
        { path: 'home3', component: home3 }
      ]
    },
    {
      path: '/register',
      name: 'register',
      component: register
    },
    {
      path: '/login',
      name: 'login',
      component: login
    }
  ]
})
